package com.example.userservice.service;


import com.example.commonapi.pojo.User;

import java.util.List;

public interface UserService {
    //    添加一个新用户
    int addUser(User user);
    //    根据Id获取一个用户
    User getUserByUsername(String username);

    void updateUsername(int id, String username);

    void deleteUser(int id);

    boolean existUsername( String username);

    void updateUserPassword(String username,String password);

    User getUserById(int id);

    List<User> totalUser();

    //    批量获取用户
    List<User> patchGetUser(List<Integer> id);

    void updateAvatar(Integer id, String url);

    User getUserByCommentId(Integer commentId);
}


